package sf.md.create.factory.abstractt;

public class Client {

    public static void main(String[] args) throws Exception {
       FactoryManager factoryManager = new FactoryManagerHandler();
       FactoryAbstracy factoryAbstracy = factoryManager.getFactory(FactoryEnum.CARFACOTYR);
       Car bigCar  = (Car) factoryAbstracy.createOjbect(CarEnum.BIGCAR);
       if(bigCar instanceof BigCar){
          System.out.println("汽车工厂生产了一辆小汽车");
      }
    }
}
